##!/bin/bash
#echo "hello,world"
#
#name="Alice"
#echo "hello,$name"
#
#echo -n "Hello,"
#echo "World"

##!/bin/bash
#echo "当前目录:$(pwd)"
#
#cd ~
#echo "已切换到Home目录:$(pwd)"
#
#cd ..
#echo "返回上一级目录:$(pwd)"

##!/bin/bash
#echo "脚本即将退出"
#exit 0

##!/bin/bash
#echo "请输入你的名字："
#read name
#echo "你好，$name"

#!/bin/bash
# 文件存在性测试
if test -e "/etc/passwd"; then
    echo "文件 /etc/passwd 存在"
else
    echo "文件 /etc/passwd 不存在"
fi

# 字符串测试
str="hello"
if test "$str" = "hello"; then
    echo "字符串匹配"
else
    echo "字符串不匹配"
fi

# 数字比较
a=5
b=10
if test $a -lt $b; then
    echo "$a 小于 $b"
fi


